package edu.sctu.zcy.month201506.day20150609;

/**
 * Created by user24 on 2015/6/9.
 */
public class TimeString1 {


    public void setTime1(){

        String time = "2015-06-09 20:46";
        String time1 = time.replace("4","5");
        System.out.println(time1);

        String time2 = time.substring(0,14);

        StringBuffer stringBuffer = new StringBuffer(time2);
        stringBuffer.append("56");
        System.out.println(stringBuffer);

        StringBuffer stringBuffer1 = new StringBuffer(time);
        stringBuffer1.replace(14,16,"56");
        System.out.println(stringBuffer1);


    }
}
